﻿package org.net.DMsg
{
	import com.gowin.Net.Structs.OtherAction;
	
	import flash.utils.IDataInput;
	//.其它玩家动作
    //@22(short)|length(short)|num(short)|[name(utf)|x(short)|y(short)|atkdir(左1右2无0)|if used property(用了1，没有0)|propertyname]...#

	public class DMsg22 extends DMsg
	{
		public var otherActions:Array= new Array();
		
		public function DMsg22()
		{
			id = 22;
		}
		
		public override function read(dis:IDataInput):void
		{
			var num:int = dis.readShort();
			for(var i:int = 0 ; i < num ; i ++)
			{
				var other:OtherAction = new OtherAction();
				other.Name = dis.readUTF();
				other.X = dis.readShort();
				other.Y = dis.readShort();
				other.AtkDir = dis.readShort();
				other.PropertyUsed = false;
				if( dis.readShort() != 0 )
				{
					other.PropertyUsed = true;
				}
				other.PropertyName = dis.readUTF();
				
				otherActions[i] = other;
			}
			
			
		}

	}
}